3.3.24 \(\int \frac {(h+i x)^2 (a+b \log (c (d+e x)^n))^2}{f+g x} \, dx\) [224]

Optimal. Leaf size=469 \[ -\frac {2 a b i (e h-d i) n x}{e g}-\frac {2 a b i (g h-f i) n x}{g^2}+\frac {2 b^2 i (e h-d i) n^2 x}{e g}+\frac {2 b^2 i (g h-f i) n^2 x}{g^2}+\frac {b^2 i^2 n^2 (d+e x)^2}{4 e^2 g}-\frac {2 b^2 i (e h-d i) n (d+e x) \log \left (c (d+e x)^n\right )}{e^2 g}-\frac {2 b^2 i (g h-f i) n (d+e x) \log \left (c (d+e x)^n\right )}{e g^2}-\frac {b i^2 n (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{2 e^2 g}+\frac {i (e h-d i) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}+\frac {i (g h-f i) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {i^2 (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{2 e^2 g}+\frac {(g h-f i)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {2 b (g h-f i)^2 n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}-\frac {2 b^2 (g h-f i)^2 n^2 \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3} \]

[Out]

-2*a*b*i*(-d*i+e*h)*n*x/e/g-2*a*b*i*(-f*i+g*h)*n*x/g^2+2*b^2*i*(-d*i+e*h)*n^2*x/e/g+2*b^2*i*(-f*i+g*h)*n^2*x/g
^2+1/4*b^2*i^2*n^2*(e*x+d)^2/e^2/g-2*b^2*i*(-d*i+e*h)*n*(e*x+d)*ln(c*(e*x+d)^n)/e^2/g-2*b^2*i*(-f*i+g*h)*n*(e*
x+d)*ln(c*(e*x+d)^n)/e/g^2-1/2*b*i^2*n*(e*x+d)^2*(a+b*ln(c*(e*x+d)^n))/e^2/g+i*(-d*i+e*h)*(e*x+d)*(a+b*ln(c*(e
*x+d)^n))^2/e^2/g+i*(-f*i+g*h)*(e*x+d)*(a+b*ln(c*(e*x+d)^n))^2/e/g^2+1/2*i^2*(e*x+d)^2*(a+b*ln(c*(e*x+d)^n))^2
/e^2/g+(-f*i+g*h)^2*(a+b*ln(c*(e*x+d)^n))^2*ln(e*(g*x+f)/(-d*g+e*f))/g^3+2*b*(-f*i+g*h)^2*n*(a+b*ln(c*(e*x+d)^
n))*polylog(2,-g*(e*x+d)/(-d*g+e*f))/g^3-2*b^2*(-f*i+g*h)^2*n^2*polylog(3,-g*(e*x+d)/(-d*g+e*f))/g^3

________________________________________________________________________________________

Rubi [A]
time = 0.38, antiderivative size = 469, normalized size of antiderivative = 1.00, number of steps used = 19, number of rules used = 12, integrand size = 31, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.387, Rules used = {2465, 2436, 2333, 2332, 2443, 2481, 2421, 6724, 2448, 2437, 2342, 2341} \begin {gather*} \frac {2 b n (g h-f i)^2 \text {PolyLog}\left (2,-\frac {g (d+e x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g^3}-\frac {2 b^2 n^2 (g h-f i)^2 \text {PolyLog}\left (3,-\frac {g (d+e x)}{e f-d g}\right )}{g^3}+\frac {i (d+e x) (e h-d i) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}-\frac {b i^2 n (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{2 e^2 g}+\frac {i^2 (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{2 e^2 g}+\frac {(g h-f i)^2 \log \left (\frac {e (f+g x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g^3}+\frac {i (d+e x) (g h-f i) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}-\frac {2 a b i n x (e h-d i)}{e g}-\frac {2 a b i n x (g h-f i)}{g^2}-\frac {2 b^2 i n (d+e x) (e h-d i) \log \left (c (d+e x)^n\right )}{e^2 g}-\frac {2 b^2 i n (d+e x) (g h-f i) \log \left (c (d+e x)^n\right )}{e g^2}+\frac {b^2 i^2 n^2 (d+e x)^2}{4 e^2 g}+\frac {2 b^2 i n^2 x (e h-d i)}{e g}+\frac {2 b^2 i n^2 x (g h-f i)}{g^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[((h + i*x)^2*(a + b*Log[c*(d + e*x)^n])^2)/(f + g*x),x]

[Out]

(-2*a*b*i*(e*h - d*i)*n*x)/(e*g) - (2*a*b*i*(g*h - f*i)*n*x)/g^2 + (2*b^2*i*(e*h - d*i)*n^2*x)/(e*g) + (2*b^2*
i*(g*h - f*i)*n^2*x)/g^2 + (b^2*i^2*n^2*(d + e*x)^2)/(4*e^2*g) - (2*b^2*i*(e*h - d*i)*n*(d + e*x)*Log[c*(d + e
*x)^n])/(e^2*g) - (2*b^2*i*(g*h - f*i)*n*(d + e*x)*Log[c*(d + e*x)^n])/(e*g^2) - (b*i^2*n*(d + e*x)^2*(a + b*L
og[c*(d + e*x)^n]))/(2*e^2*g) + (i*(e*h - d*i)*(d + e*x)*(a + b*Log[c*(d + e*x)^n])^2)/(e^2*g) + (i*(g*h - f*i
)*(d + e*x)*(a + b*Log[c*(d + e*x)^n])^2)/(e*g^2) + (i^2*(d + e*x)^2*(a + b*Log[c*(d + e*x)^n])^2)/(2*e^2*g) +
 ((g*h - f*i)^2*(a + b*Log[c*(d + e*x)^n])^2*Log[(e*(f + g*x))/(e*f - d*g)])/g^3 + (2*b*(g*h - f*i)^2*n*(a + b
*Log[c*(d + e*x)^n])*PolyLog[2, -((g*(d + e*x))/(e*f - d*g))])/g^3 - (2*b^2*(g*h - f*i)^2*n^2*PolyLog[3, -((g*
(d + e*x))/(e*f - d*g))])/g^3

Rule 2332

Int[Log[(c_.)*(x_)^(n_.)], x_Symbol] :> Simp[x*Log[c*x^n], x] - Simp[n*x, x] /; FreeQ[{c, n}, x]

Rule 2333

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.), x_Symbol] :> Simp[x*(a + b*Log[c*x^n])^p, x] - Dist[b*n*p, In
t[(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{a, b, c, n}, x] && GtQ[p, 0] && IntegerQ[2*p]

Rule 2341

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Log[c*x^
n])/(d*(m + 1))), x] - Simp[b*n*((d*x)^(m + 1)/(d*(m + 1)^2)), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rule 2342

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Lo
g[c*x^n])^p/(d*(m + 1))), x] - Dist[b*n*(p/(m + 1)), Int[(d*x)^m*(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{
a, b, c, d, m, n}, x] && NeQ[m, -1] && GtQ[p, 0]

Rule 2421

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> Simp
[(-PolyLog[2, (-d)*f*x^m])*((a + b*Log[c*x^n])^p/m), x] + Dist[b*n*(p/m), Int[PolyLog[2, (-d)*f*x^m]*((a + b*L
og[c*x^n])^(p - 1)/x), x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 2436

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.), x_Symbol] :> Dist[1/e, Subst[Int[(a + b*Log[c*
x^n])^p, x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, n, p}, x]

Rule 2437

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_) + (g_.)*(x_))^(q_.), x_Symbol] :> Dist[1/
e, Subst[Int[(f*(x/d))^q*(a + b*Log[c*x^n])^p, x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p, q}, x]
 && EqQ[e*f - d*g, 0]

Rule 2443

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)/((f_.) + (g_.)*(x_)), x_Symbol] :> Simp[Log[e*((
f + g*x)/(e*f - d*g))]*((a + b*Log[c*(d + e*x)^n])^p/g), x] - Dist[b*e*n*(p/g), Int[Log[(e*(f + g*x))/(e*f - d
*g)]*((a + b*Log[c*(d + e*x)^n])^(p - 1)/(d + e*x)), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p}, x] && NeQ[e*
f - d*g, 0] && IGtQ[p, 1]

Rule 2448

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)*((f_.) + (g_.)*(x_))^(q_.), x_Symbol] :> Int[Exp
andIntegrand[(f + g*x)^q*(a + b*Log[c*(d + e*x)^n])^p, x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p}, x] && NeQ[
e*f - d*g, 0] && IGtQ[q, 0]

Rule 2465

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*(RFx_), x_Symbol] :> With[{u = ExpandIntegrand[
(a + b*Log[c*(d + e*x)^n])^p, RFx, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, d, e, n}, x] && RationalFunct
ionQ[RFx, x] && IntegerQ[p]

Rule 2481

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + Log[(h_.)*((i_.) + (j_.)*(x_))^(m_.)]*
(g_.))*((k_.) + (l_.)*(x_))^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[(k*(x/d))^r*(a + b*Log[c*x^n])^p*(f + g*Lo
g[h*((e*i - d*j)/e + j*(x/e))^m]), x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, j, k, l, n, p, r},
 x] && EqQ[e*k - d*l, 0]

Rule 6724

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin {align*} \int \frac {(h+224 x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{f+g x} \, dx &=\int \left (\frac {224 (-224 f+g h) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g^2}+\frac {224 (h+224 x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g}+\frac {(-224 f+g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g^2 (f+g x)}\right ) \, dx\\ &=\frac {224 \int (h+224 x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \, dx}{g}-\frac {(224 (224 f-g h)) \int \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \, dx}{g^2}+\frac {(224 f-g h)^2 \int \frac {\left (a+b \log \left (c (d+e x)^n\right )\right )^2}{f+g x} \, dx}{g^2}\\ &=\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {224 \int \left (\frac {(-224 d+e h) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e}+\frac {224 (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e}\right ) \, dx}{g}-\frac {(224 (224 f-g h)) \text {Subst}\left (\int \left (a+b \log \left (c x^n\right )\right )^2 \, dx,x,d+e x\right )}{e g^2}-\frac {\left (2 b e (224 f-g h)^2 n\right ) \int \frac {\left (a+b \log \left (c (d+e x)^n\right )\right ) \log \left (\frac {e (f+g x)}{e f-d g}\right )}{d+e x} \, dx}{g^3}\\ &=-\frac {224 (224 f-g h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {50176 \int (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \, dx}{e g}-\frac {(224 (224 d-e h)) \int \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \, dx}{e g}+\frac {(448 b (224 f-g h) n) \text {Subst}\left (\int \left (a+b \log \left (c x^n\right )\right ) \, dx,x,d+e x\right )}{e g^2}-\frac {\left (2 b (224 f-g h)^2 n\right ) \text {Subst}\left (\int \frac {\left (a+b \log \left (c x^n\right )\right ) \log \left (\frac {e \left (\frac {e f-d g}{e}+\frac {g x}{e}\right )}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{g^3}\\ &=\frac {448 a b (224 f-g h) n x}{g^2}-\frac {224 (224 f-g h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {2 b (224 f-g h)^2 n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}+\frac {50176 \text {Subst}\left (\int x \left (a+b \log \left (c x^n\right )\right )^2 \, dx,x,d+e x\right )}{e^2 g}-\frac {(224 (224 d-e h)) \text {Subst}\left (\int \left (a+b \log \left (c x^n\right )\right )^2 \, dx,x,d+e x\right )}{e^2 g}+\frac {\left (448 b^2 (224 f-g h) n\right ) \text {Subst}\left (\int \log \left (c x^n\right ) \, dx,x,d+e x\right )}{e g^2}-\frac {\left (2 b^2 (224 f-g h)^2 n^2\right ) \text {Subst}\left (\int \frac {\text {Li}_2\left (-\frac {g x}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{g^3}\\ &=\frac {448 a b (224 f-g h) n x}{g^2}-\frac {448 b^2 (224 f-g h) n^2 x}{g^2}+\frac {448 b^2 (224 f-g h) n (d+e x) \log \left (c (d+e x)^n\right )}{e g^2}-\frac {224 (224 d-e h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}-\frac {224 (224 f-g h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {25088 (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}+\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {2 b (224 f-g h)^2 n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}-\frac {2 b^2 (224 f-g h)^2 n^2 \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}-\frac {(50176 b n) \text {Subst}\left (\int x \left (a+b \log \left (c x^n\right )\right ) \, dx,x,d+e x\right )}{e^2 g}+\frac {(448 b (224 d-e h) n) \text {Subst}\left (\int \left (a+b \log \left (c x^n\right )\right ) \, dx,x,d+e x\right )}{e^2 g}\\ &=\frac {448 a b (224 d-e h) n x}{e g}+\frac {448 a b (224 f-g h) n x}{g^2}-\frac {448 b^2 (224 f-g h) n^2 x}{g^2}+\frac {12544 b^2 n^2 (d+e x)^2}{e^2 g}+\frac {448 b^2 (224 f-g h) n (d+e x) \log \left (c (d+e x)^n\right )}{e g^2}-\frac {25088 b n (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{e^2 g}-\frac {224 (224 d-e h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}-\frac {224 (224 f-g h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {25088 (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}+\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {2 b (224 f-g h)^2 n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}-\frac {2 b^2 (224 f-g h)^2 n^2 \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}+\frac {\left (448 b^2 (224 d-e h) n\right ) \text {Subst}\left (\int \log \left (c x^n\right ) \, dx,x,d+e x\right )}{e^2 g}\\ &=\frac {448 a b (224 d-e h) n x}{e g}+\frac {448 a b (224 f-g h) n x}{g^2}-\frac {448 b^2 (224 d-e h) n^2 x}{e g}-\frac {448 b^2 (224 f-g h) n^2 x}{g^2}+\frac {12544 b^2 n^2 (d+e x)^2}{e^2 g}+\frac {448 b^2 (224 d-e h) n (d+e x) \log \left (c (d+e x)^n\right )}{e^2 g}+\frac {448 b^2 (224 f-g h) n (d+e x) \log \left (c (d+e x)^n\right )}{e g^2}-\frac {25088 b n (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )}{e^2 g}-\frac {224 (224 d-e h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}-\frac {224 (224 f-g h) (d+e x) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e g^2}+\frac {25088 (d+e x)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{e^2 g}+\frac {(224 f-g h)^2 \left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )}{g^3}+\frac {2 b (224 f-g h)^2 n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text {Li}_2\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}-\frac {2 b^2 (224 f-g h)^2 n^2 \text {Li}_3\left (-\frac {g (d+e x)}{e f-d g}\right )}{g^3}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.35, size = 876, normalized size = 1.87 \begin {gather*} \frac {4 e^2 g i (2 g h-f i) x \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^2+2 e^2 g^2 i^2 x^2 \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^2+4 e^2 (g h-f i)^2 \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right )^2 \log (f+g x)+8 b e^2 g^2 h^2 n \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right ) \left (\log (d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )+\text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )\right )+2 b i^2 n \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right ) \left (e g (e x (4 f-g x)+2 d (2 f+g x))-2 \log (d+e x) \left (g (d+e x) (2 e f+d g-e g x)-2 e^2 f^2 \log \left (\frac {e (f+g x)}{e f-d g}\right )\right )+4 e^2 f^2 \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )\right )-16 b e g h i n \left (a-b n \log (d+e x)+b \log \left (c (d+e x)^n\right )\right ) \left (-g (d+e x) (-1+\log (d+e x))+e f \left (\log (d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )+\text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )\right )\right )+8 b^2 e g h i n^2 \left (g \left (2 e x-2 (d+e x) \log (d+e x)+(d+e x) \log ^2(d+e x)\right )-e f \left (\log ^2(d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )+2 \log (d+e x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )-2 \text {Li}_3\left (\frac {g (d+e x)}{-e f+d g}\right )\right )\right )-b^2 i^2 n^2 \left (4 e f g \left (2 e x-2 (d+e x) \log (d+e x)+(d+e x) \log ^2(d+e x)\right )+g^2 \left (e x (6 d-e x)+\left (-6 d^2-4 d e x+2 e^2 x^2\right ) \log (d+e x)+2 \left (d^2-e^2 x^2\right ) \log ^2(d+e x)\right )-4 e^2 f^2 \left (\log ^2(d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )+2 \log (d+e x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )-2 \text {Li}_3\left (\frac {g (d+e x)}{-e f+d g}\right )\right )\right )+4 b^2 e^2 g^2 h^2 n^2 \left (\log ^2(d+e x) \log \left (\frac {e (f+g x)}{e f-d g}\right )+2 \log (d+e x) \text {Li}_2\left (\frac {g (d+e x)}{-e f+d g}\right )-2 \text {Li}_3\left (\frac {g (d+e x)}{-e f+d g}\right )\right )}{4 e^2 g^3} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[((h + i*x)^2*(a + b*Log[c*(d + e*x)^n])^2)/(f + g*x),x]

[Out]

(4*e^2*g*i*(2*g*h - f*i)*x*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])^2 + 2*e^2*g^2*i^2*x^2*(a - b*n*Log[d
+ e*x] + b*Log[c*(d + e*x)^n])^2 + 4*e^2*(g*h - f*i)^2*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])^2*Log[f +
 g*x] + 8*b*e^2*g^2*h^2*n*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])*(Log[d + e*x]*Log[(e*(f + g*x))/(e*f -
 d*g)] + PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)]) + 2*b*i^2*n*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])*(
e*g*(e*x*(4*f - g*x) + 2*d*(2*f + g*x)) - 2*Log[d + e*x]*(g*(d + e*x)*(2*e*f + d*g - e*g*x) - 2*e^2*f^2*Log[(e
*(f + g*x))/(e*f - d*g)]) + 4*e^2*f^2*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)]) - 16*b*e*g*h*i*n*(a - b*n*Log[
d + e*x] + b*Log[c*(d + e*x)^n])*(-(g*(d + e*x)*(-1 + Log[d + e*x])) + e*f*(Log[d + e*x]*Log[(e*(f + g*x))/(e*
f - d*g)] + PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)])) + 8*b^2*e*g*h*i*n^2*(g*(2*e*x - 2*(d + e*x)*Log[d + e*x
] + (d + e*x)*Log[d + e*x]^2) - e*f*(Log[d + e*x]^2*Log[(e*(f + g*x))/(e*f - d*g)] + 2*Log[d + e*x]*PolyLog[2,
 (g*(d + e*x))/(-(e*f) + d*g)] - 2*PolyLog[3, (g*(d + e*x))/(-(e*f) + d*g)])) - b^2*i^2*n^2*(4*e*f*g*(2*e*x -
2*(d + e*x)*Log[d + e*x] + (d + e*x)*Log[d + e*x]^2) + g^2*(e*x*(6*d - e*x) + (-6*d^2 - 4*d*e*x + 2*e^2*x^2)*L
og[d + e*x] + 2*(d^2 - e^2*x^2)*Log[d + e*x]^2) - 4*e^2*f^2*(Log[d + e*x]^2*Log[(e*(f + g*x))/(e*f - d*g)] + 2
*Log[d + e*x]*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)] - 2*PolyLog[3, (g*(d + e*x))/(-(e*f) + d*g)])) + 4*b^2*
e^2*g^2*h^2*n^2*(Log[d + e*x]^2*Log[(e*(f + g*x))/(e*f - d*g)] + 2*Log[d + e*x]*PolyLog[2, (g*(d + e*x))/(-(e*
f) + d*g)] - 2*PolyLog[3, (g*(d + e*x))/(-(e*f) + d*g)]))/(4*e^2*g^3)

________________________________________________________________________________________

Maple [F]
time = 0.33, size = 0, normalized size = 0.00 \[\int \frac {\left (i x +h \right )^{2} \left (a +b \ln \left (c \left (e x +d \right )^{n}\right )\right )^{2}}{g x +f}\, dx\]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((i*x+h)^2*(a+b*ln(c*(e*x+d)^n))^2/(g*x+f),x)

[Out]

int((i*x+h)^2*(a+b*ln(c*(e*x+d)^n))^2/(g*x+f),x)

________________________________________________________________________________________

Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^2*(a+b*log(c*(e*x+d)^n))^2/(g*x+f),x, algorithm="maxima")

[Out]

2*I*a^2*h*(x/g - f*log(g*x + f)/g^2) + a^2*h^2*log(g*x + f)/g - 1/2*a^2*(2*f^2*log(g*x + f)/g^3 + (g*x^2 - 2*f
*x)/g^2) - integrate(-(b^2*h^2*log(c)^2 + 2*a*b*h^2*log(c) - (b^2*log(c)^2 + 2*a*b*log(c))*x^2 + (b^2*h^2 + 2*
I*b^2*h*x - b^2*x^2)*log((x*e + d)^n)^2 + 2*(I*b^2*h*log(c)^2 + 2*I*a*b*h*log(c))*x + 2*(b^2*h^2*log(c) + a*b*
h^2 - (b^2*log(c) + a*b)*x^2 + 2*(I*b^2*h*log(c) + I*a*b*h)*x)*log((x*e + d)^n))/(g*x + f), x)

________________________________________________________________________________________

Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^2*(a+b*log(c*(e*x+d)^n))^2/(g*x+f),x, algorithm="fricas")

[Out]

integral((a^2*h^2 + 2*I*a^2*h*x - a^2*x^2 + (b^2*h^2*n^2 + 2*I*b^2*h*n^2*x - b^2*n^2*x^2)*log(x*e + d)^2 + (b^
2*h^2 + 2*I*b^2*h*x - b^2*x^2)*log(c)^2 + 2*(a*b*h^2*n + 2*I*a*b*h*n*x - a*b*n*x^2 + (b^2*h^2*n + 2*I*b^2*h*n*
x - b^2*n*x^2)*log(c))*log(x*e + d) + 2*(a*b*h^2 + 2*I*a*b*h*x - a*b*x^2)*log(c))/(g*x + f), x)

________________________________________________________________________________________

Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {\left (a + b \log {\left (c \left (d + e x\right )^{n} \right )}\right )^{2} \left (h + i x\right )^{2}}{f + g x}\, dx \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)**2*(a+b*ln(c*(e*x+d)**n))**2/(g*x+f),x)

[Out]

Integral((a + b*log(c*(d + e*x)**n))**2*(h + i*x)**2/(f + g*x), x)

________________________________________________________________________________________

Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((i*x+h)^2*(a+b*log(c*(e*x+d)^n))^2/(g*x+f),x, algorithm="giac")

[Out]

integrate((b*log((x*e + d)^n*c) + a)^2*(h + I*x)^2/(g*x + f), x)

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {{\left (h+i\,x\right )}^2\,{\left (a+b\,\ln \left (c\,{\left (d+e\,x\right )}^n\right )\right )}^2}{f+g\,x} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((h + i*x)^2*(a + b*log(c*(d + e*x)^n))^2)/(f + g*x),x)

[Out]

int(((h + i*x)^2*(a + b*log(c*(d + e*x)^n))^2)/(f + g*x), x)

________________________________________________________________________________________